home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part2 / 16562 < prev    next >
Encoding:
Text File  |  1996-08-05  |  2.5 KB  |  56 lines

  1. Newsgroups: comp.lang.ada,comp.lang.c,comp.lang.c++,comp.edu
  2. Path: uu4news.netcom.com!telesoft!kst
  3. From: kst@thomsoft.com (Keith Thompson)
  4. Subject: Re: ANSI C and POSIX (was Re: C/C++ knocks the crap out of Ada)
  5. X-Nntp-Posting-Host: pulsar
  6. Message-ID: <DpovII.CC9@thomsoft.com>
  7. Originator: kst@pulsar
  8. Sender: news@thomsoft.com (USENET News Admin @flash)
  9. Organization: Thomson Software Products, San Diego, CA, USA
  10. References: <JSA.96Feb16135027@organon.com> <dewar.828757752@schonberg> <danpop.828819479@rscernix> <dewar.828879781@schonberg> <4k9qhe$65r@solutions.solon.com> <dewar.828936837@schonberg> <828964950snz@genesis.demon.co.uk> <4kbfup$2vd@news1.mnsinc.com> <4kbl5i$p3@mordred.gatech.edu> <dewar.828992408@schonberg>
  11. Date: Thu, 11 Apr 1996 08:27:54 GMT
  12.  
  13. In <dewar.828992408@schonberg> dewar@cs.nyu.edu (Robert Dewar) writes:
  14. [...]
  15. > A competent compiler tries to implement 100% of the required standard
  16. > functionality, plus as much as possible of the expected behavior that
  17. > goes beyond this standard, consistent with not damaging the quality
  18. > of code, or the performance of the compiler, too severely.
  19.  
  20. On the other hand, it's tempting to suggest that a compiler should
  21. implement 100% of the required functionality and as *little* as possible
  22. of the expected behavior that goes beyond the standard.  For example:
  23.  
  24.     As many instances as possible of erroneous execution are detected
  25.     and raise Program_Error.
  26.  
  27.     No predefined integer types other than Integer, and no predefined
  28.     floating-point types other than Float.
  29.  
  30.     Elaboration order is chosen to *maximize* the likelihood of
  31.     access-before-elaboration errors.
  32.  
  33.     Unchecked_Conversion behaves strangely in some cases.
  34.  
  35.     Access values are not addresses.  Different access types are
  36.     represented differently.
  37.  
  38.     The internal representation of a null access value or address is
  39.     not 0.
  40.  
  41.     Perverse task scheduling to the extent allowed by the standard.
  42.  
  43. Similar ideas can be applied to languages other than Ada.
  44.  
  45. Porting existing code to such a compiler could be an excellent way to
  46. filter out bugs and non-portable constructs.
  47.  
  48. More realistically, it might be a good idea to implement this kind of
  49. thing as a compiler option; the default behavior should be more forgiving.
  50.  
  51. -- 
  52. Keith Thompson (The_Other_Keith) kst@thomsoft.com <*>
  53. TeleSoft^H^H^H^H^H^H^H^H Alsys^H^H^H^H^H Thomson Software Products
  54. 10251 Vista Sorrento Parkway, Suite 300, San Diego, CA, USA, 92121-2718
  55. This sig uses the word "Exon" in violation of the Communications Decency Act.
  56.